package com.itqf.mapper;

import com.itqf.bean.DtsOrder;
import com.itqf.bean.DtsOrderExample;
import com.itqf.vo.CategorySellAmts;
import com.itqf.vo.DayStatis;
import org.apache.ibatis.annotations.Param;

import java.util.List;

public interface DtsOrderMapper {
    long countByExample(DtsOrderExample example);

    int deleteByExample(DtsOrderExample example);

    int deleteByPrimaryKey(Integer id);

    int insert(DtsOrder record);

    int insertSelective(DtsOrder record);

    List<DtsOrder> selectByExample(DtsOrderExample example);

    DtsOrder selectByPrimaryKey(Integer id);

    int updateByExampleSelective(@Param("record") DtsOrder record, @Param("example") DtsOrderExample example);

    int updateByExample(@Param("record") DtsOrder record, @Param("example") DtsOrderExample example);

    int updateByPrimaryKeySelective(DtsOrder record);

    int updateByPrimaryKey(DtsOrder record);

    /**
     * 根据品牌查询响应的订单
     * @param brandIds
     * @return
     */
    Long selectTotalByBrandIds(List<Integer> brandIds);

    /**
     * 查询类别销售额
     * @return
     */
    List<CategorySellAmts> selectSell();

    /**
     * 订单的日增长量和销售额
     * @return
     */
    List<DayStatis> selectDaySell();
}